skip to main content
research-article

Refining Cache Behavior Prediction Using Cache Miss Paths

Published:11 May 2017Publication History
Skip Abstract Section

Abstract

Worst-Case Execution Time (WCET) is an important metric for programs running on real-time systems, and finding precise estimates of a program’s WCET is crucial to avoid wastage of hardware resources and to improve the schedulability of task sets. Caches have a major impact on a program’s execution time, and accurate estimation of a program’s cache behavior can lead to significant reduction in its estimated WCET. The traditional approach to cache analysis generally targets the worst-case cache behavior of individual cache accesses and provides a safe hit-miss classification for every individual access. In this work, we show that these classifications are not sufficient to precisely capture cache behavior, since they apply to individual accesses, and often, more precise predictions can be made about groups of accesses. Further, memory accesses inside loops may show the worst-case behavior only for a subset of the iteration space. In order to predict such behavior in a scalable fashion, we use the fact that the cache behavior of an access mostly depends only on the memory accesses made in the immediate vicinity, and hence we analyze a small, fixed-size neighborhood of every access with complete precision and summarize the resulting information in the form of cache miss paths. A variety of analyses are then performed on the cache miss paths to make precise predictions about cache behavior. We also demonstrate precision issues in Abstract Interpretation-based Must and Persistence cache analysis that can be easily solved using cache miss paths. Experimental results over a wide range of benchmarks demonstrate precision improvement in WCET of multipath programs over previous approaches, and we also show how to integrate our approach with other microarchitectural analysis such as pipeline analysis.

Skip Supplemental Material Section

Supplemental Material

References

  1. Alfred V. Aho, Ravi Sethi, and Jeffrey D. Ullman. 1986. Compilers, Principles, Techniques. Addison Wesley.Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Martin Alt, Christian Ferdinand, Florian Martin, and Reinhard Wilhelm. 1996. Cache behavior prediction by abstract interpretation. In SAS. Springer-Verlag. Google ScholarGoogle ScholarCross RefCross Ref
  3. S. Andalam, R. Sinha, P. Roop, A. Girault, and J. Reineke. 2013. Precise timing analysis for direct-mapped caches. In Proceedings of the 2013 50th ACM/EDAC/IEEE Design Automation Conference (DAC’13). 1--10. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Abhijeet Banerjee, Sudipta Chattopadhyay, and Abhik Roychoudhury. 2013. Precise micro-architectural modeling for WCET analysis via AI+SAT. In RTAS.Google ScholarGoogle Scholar
  5. Pavol Cerny, Thomas A. Henzinger, and Arjun Radhakrishna. 2013. Quantitative abstraction refinement. In POPL. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Sudipta Chattopadhyay and Abhik Roychoudhury. 2011. Scalable and precise refinement of cache timing analysis via model checking. In RTSS. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Duc-Hiep Chu, Joxan Jaffar, and Rasool Maghareh. 2016. Precise cache timing analysis via symbolic execution. In RTAS. Google ScholarGoogle ScholarCross RefCross Ref
  8. Christoph Cullmann. 2013. Cache persistence analysis: Theory and practice. ACM Transactions on Embedded Computing Systems (TECS) 12, 1s (2013), 40.Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Andreas Engelbredt Dalsgaard, Mads C. Olesen, Martin Toft, Ren Rydhof Hansen, and Kim Guldstrand Larsen. 2010. METAMOC: Modular execution time analysis using model checking. In Worst-Case Execution Time Analysis. 113--123. DOI:http://dx.doi.org/10.4230/OASIcs.WCET.2010.113Google ScholarGoogle Scholar
  10. Christian Ferdinand and Reinhard Wilhelm. 1999. Efficient and precise cache behavior prediction for real-time systems. Real-Time Systems 17, 2--3 (Dec. 1999), 131--181.Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Andreas Gustavsson, Andreas Ermedahl, Björn Lisper, and Paul Pettersson. 2010. Towards WCET analysis of multicore architectures using UPPAAL. In WCET.Google ScholarGoogle Scholar
  12. Bach Khoa Huynh, Lei Ju, and Abhik Roychoudhury. 2011. Scope-aware data cache analysis for WCET estimation. In RTAS. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Xianfeng Li, Yun Liang, Tulika Mitra, and Abhik Roychoudury. 2007. Chronos: A timing analyzer for embedded software. Science of Computer Programming 69, 1--3 (2007), 56--67.Google ScholarGoogle ScholarCross RefCross Ref
  14. Xianfeng Li, Abhik Roychoudhury, and Tulika Mitra. 2006. Modeling out-of-order processors for WCET analysis. Real-Time Systems 34, 3 (2006), 195--227. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Y.-T. S. Li, Sharad Malik, and Andrew Wolfe. 1995. Efficient microarchitecture modeling and path analysis for real-time software. In RTSS.Google ScholarGoogle Scholar
  16. Y.-T. S. Li, Sharad Malik, and Andrew Wolfe. 1996. Cache modeling for real-time software: Beyond direct mapped instruction caches. In RTSS.Google ScholarGoogle Scholar
  17. Mingsong Lv, Nan Guan, Qingxu Deng, Ge Yu, and Wang Yi. 2011. McAiT A timing analyzer for multicore real-time software. In Automated Technology for Verification and Analysis. Google ScholarGoogle ScholarCross RefCross Ref
  18. Frank Mueller. 2000. Timing analysis for instruction caches. Real-Time Systems 18, 2--3 (2000), 217--247.Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. Kartik Nagar and Y. N. Srikant. 2015. Path sensitive cache analysis using cache miss paths. In VMCAI. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Ingomar Wenzel, Raimund Kirner, Peter Puschner, and Bernhard Rieder. 2005. Principles of timing anomalies in superscalar processors. In Proceedings of the 5th International Conference on Quality Software, 2005 (QSIC’05). IEEE, 295--303. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Reinhard Wilhelm. 2004. Why AI + ILP is good for WCET, but MC is not, nor ILP alone. In VMCAI.Google ScholarGoogle Scholar
  22. Stephan Wilhelm and Björn Wachter. 2009. Symbolic state traversal for WCET analysis. In Proceedings of the 7th ACM International Conference on Embedded Software (EMSOFT’09). 137--146. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Refining Cache Behavior Prediction Using Cache Miss Paths

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in

      Full Access

      • Published in

        cover image ACM Transactions on Embedded Computing Systems
        ACM Transactions on Embedded Computing Systems  Volume 16, Issue 4
        Special Issue on Secure and Fault-Tolerant Embedded Computing and Regular Papers
        November 2017
        614 pages
        ISSN:1539-9087
        EISSN:1558-3465
        DOI:10.1145/3092956
        Issue’s Table of Contents

        Copyright © 2017 ACM

        Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

        Publisher

        Association for Computing Machinery

        New York, NY, United States

        Publication History

        • Published: 11 May 2017
        • Accepted: 1 January 2017
        • Revised: 1 December 2016
        • Received: 1 June 2016
        Published in tecs Volume 16, Issue 4

        Permissions

        Request permissions about this article.

        Request Permissions

        Check for updates

        Qualifiers

        • research-article
        • Research
        • Refereed

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader